package com.cyrus.vueboot.error;

/**
 * @Author: Cyrus
 * @CreateDate: 2020/12/6
 */
public enum  CommonError implements ErrorCode {
    SUCCESS(200, "操作成功"),
    E_10001(10001, "增加失败"),
    E_10002(10002, "删除失败"),
    E_10003(10003, "修改失败"),
    E_10004(10004, "查询失败"),
    E_99999(99999,"未知错误");

    private int code;

    private String msg;

    @Override
    public int getCode() {
        return code;
    }

    @Override
    public String getMsg() {
        return msg;
    }

    CommonError(int code, String desc) {
        this.code = code;
        this.msg = desc;
    }
}
